package com.tender.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.tender.service.MqOrdinaryProducer;

@RestController
@RequestMapping("/ordinary")
public class MqOrdinaryProducerController {

    @Autowired
    private MqOrdinaryProducer mqOrdinaryProducer;

    @GetMapping("/sendMq")
    public String sendMq() {
        mqOrdinaryProducer.sendMq();

        return "success 4 sendMq";
    }
    @GetMapping("/sync")
    public String sync() {
        mqOrdinaryProducer.sync();

        return "success 4 sync";
    }

    @GetMapping("/async")
    public String async() {
        mqOrdinaryProducer.async();

        return "success 4 async";
    }

}
